﻿using System;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Events;
using UnityEngine.UI;

// Token: 0x020003B1 RID: 945
public class MoveableThumbnailSelectUI : MonoBehaviour
{
	// Token: 0x1700024C RID: 588
	// (get) Token: 0x0600178C RID: 6028 RVA: 0x0009C28C File Offset: 0x0009A48C
	public bool isShow
	{
		get
		{
			return this.moveable.isActiveAndEnabled;
		}
	}

	// Token: 0x1700024D RID: 589
	// (get) Token: 0x0600178D RID: 6029 RVA: 0x0009C29C File Offset: 0x0009A49C
	public bool isOpen
	{
		get
		{
			return this.moveable.State == MoveableUI.STATE.OPEN;
		}
	}

	// Token: 0x1700024E RID: 590
	// (get) Token: 0x0600178E RID: 6030 RVA: 0x0009C2AC File Offset: 0x0009A4AC
	// (set) Token: 0x0600178F RID: 6031 RVA: 0x0009C2B4 File Offset: 0x0009A4B4
	public Selectable openUI { get; private set; }

	// Token: 0x06001790 RID: 6032 RVA: 0x0009C2C0 File Offset: 0x0009A4C0
	public void Setup(string str, List<CustomSelectSet> setDatas, UnityAction<MoveableUI.STATE> onChangeState, UnityAction<CustomSelectSet> onSelectAct)
	{
		this.moveable.SetTitle(str);
		this.moveable.RemoveAllListenersOnChange();
		this.moveable.AddOnChange(onChangeState);
		this.select.SetDatas(setDatas);
		this.select.RemoveAllListenersOnSelectAction();
		this.select.AddOnSelectAction(onSelectAct);
		this.UpdateEnables();
	}

	// Token: 0x06001791 RID: 6033 RVA: 0x0009C31C File Offset: 0x0009A51C
	public void Open(Selectable ui)
	{
		this.openUI = ui;
		this.moveable.Open();
		MoveableColorCustomUI[] array = UnityEngine.Object.FindObjectsOfType<MoveableColorCustomUI>();
		for (int i = 0; i < array.Length; i++)
		{
			array[i].Close();
		}
	}

	// Token: 0x06001792 RID: 6034 RVA: 0x0009C360 File Offset: 0x0009A560
	public void Close()
	{
		this.moveable.Close();
	}

	// Token: 0x06001793 RID: 6035 RVA: 0x0009C370 File Offset: 0x0009A570
	public void SetSelectedNo(int no)
	{
		this.select.SetSelectedNo(no);
	}

	// Token: 0x06001794 RID: 6036 RVA: 0x0009C380 File Offset: 0x0009A580
	public void SetSelectedFromDataID(int id)
	{
		this.select.SetSelectedFromDataID(id);
	}

	// Token: 0x06001795 RID: 6037 RVA: 0x0009C390 File Offset: 0x0009A590
	public CustomSelectSet GetSelectedData()
	{
		return this.select.GetSelectedData();
	}

	// Token: 0x06001796 RID: 6038 RVA: 0x0009C3A0 File Offset: 0x0009A5A0
	public void UpdateEnables()
	{
		this.select.UpdateEnables();
	}

	// Token: 0x04001B29 RID: 6953
	[SerializeField]
	private MoveableUI moveable;

	// Token: 0x04001B2A RID: 6954
	[SerializeField]
	private ThumbnailSelectUI select;
}
